﻿/***********************************************************************
 * <copyright file="IStock.cs" company="BUCA JSC">
 * -->    Copyright (C) statement. All right reserved
 * </copyright>
 * 
 * Created:   LinhMC
 * Email:    linhmc@buca.vn
 * Website:
 * Create Date: Tuesday, October 22, 2013
 * Usage: 
 * 
 * RevisionHistory: 
 * Date         Author               Description 
 * 
 * ************************************************************************/

using System.Collections.Generic;
using BusinessObjects.BussinessDictionary;

namespace DataObjects.StandartInterfaces.Dictionary
{
    /// <summary>
    /// Defines methods to access Stock
    /// </summary>
    /// <remarks>
    /// This is a database-independent interface. Implementations are database specific
    /// </remarks>
    public interface IStockDao  
    {
        /// <summary>
        /// Gets the paged.
        /// </summary>
        /// <param name="unitId">The unit identifier.</param>
        /// <param name="currentPage">The current page.</param>
        /// <returns></returns>
        List<Stock> GetPaged(int unitId, int currentPage);

        /// <summary>
        /// Gets the stock by unit.
        /// </summary>
        /// <param name="unitId">The unit identifier.</param>
        /// <returns></returns>
        List<Stock> GetStockByUnit(int unitId); 

        /// <summary>
        /// Gets the size of the page.
        /// </summary>
        /// <param name="unitId">The unit identifier.</param>
        
        /// <returns></returns>
        int GetPageSize(int unitId);

        

          /// <summary>
        /// Gets the stocks by unit.
        /// </summary>
        /// <param name="stockId">The unit identifier.</param>
        /// <returns></returns>
        Stock GetStock(int stockId); 

        
        /// <summary>
        /// Inserts the stock.
        /// </summary>
        /// <param name="stock">The stock.</param>
        string InsertStock(Stock stock);

        /// <summary>
        /// Updates the stock.
        /// </summary>
        /// <param name="stock">The stock.</param>
        string UpdateStock(Stock stock);

        /// <summary>
        /// Deletes the stock.
        /// </summary>
        /// <param name="stock">The stock.</param>
        string DeleteStock(Stock stock);
    }
}
